﻿<UserControl
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
             xmlns:controls="clr-namespace:MahApps.Metro.Controls;assembly=MahApps.Metro"

             x:Class="monitor_server_2_WPF.AccessListTabControl"
             
             mc:Ignorable="d" ScrollViewer.CanContentScroll="True" UseLayoutRounding="False" d:DesignWidth="555.333">

    <UserControl.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <!--<ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Colours.xaml" />-->
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Fonts.xaml" />
                <!--<ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Controls.xaml" />-->
                <!--<ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Accents/Blue.xaml" />-->
                <!--<ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Accents/BaseLight.xaml" />-->
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Controls.Buttons.xaml"/>
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Controls.AnimatedSingleRowTabControl.xaml" />
            </ResourceDictionary.MergedDictionaries>
            <Style x:Key="TabItemStyle1" TargetType="{x:Type TabItem}">
                <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
                <Setter Property="IsTabStop" Value="False"/>
                <Setter Property="BorderThickness" Value="1"/>
                <Setter Property="Padding" Value="6,2"/>
                <Setter Property="HorizontalContentAlignment" Value="Stretch"/>
                <Setter Property="VerticalContentAlignment" Value="Stretch"/>
                <Setter Property="MinWidth" Value="5"/>
                <Setter Property="MinHeight" Value="5"/>
                <Setter Property="Template">
                    <Setter.Value>
                        <ControlTemplate TargetType="{x:Type TabItem}">
                            <Label x:Name="root" FontSize="26.67">
                                <ContentPresenter ContentTemplate="{TemplateBinding HeaderTemplate}" Content="{TemplateBinding Header}" ContentStringFormat="{TemplateBinding HeaderStringFormat}" ContentSource="Header" RecognizesAccessKey="True"/>
                            </Label>
                            <ControlTemplate.Triggers>
                                <Trigger Property="IsSelected" Value="True">
                                    <Setter Property="Foreground" TargetName="root">
                                        <Setter.Value>
                                            <!--<SolidColorBrush Color="{DynamicResource AccentColor}"/>-->
                                            <SolidColorBrush Color="DeepSkyBlue"/>
                                        </Setter.Value>
                                    </Setter>
                                </Trigger>
                                <Trigger Property="IsMouseOver" SourceName="root" Value="True">
                                    <Setter Property="Foreground" TargetName="root" Value="GreenYellow"/>
                                </Trigger>
                            </ControlTemplate.Triggers>
                        </ControlTemplate>
                    </Setter.Value>
                </Setter>
            </Style>
            
        </ResourceDictionary>
    </UserControl.Resources>
    <Grid Margin="0,0,0,0">
        <TabControl ItemContainerStyle="{DynamicResource TabItemStyle1}" x:Name="MainTab" Margin="0,0,0,0" VerticalContentAlignment="Stretch" HorizontalContentAlignment="Center" ScrollViewer.CanContentScroll="True">
            <TabItem  x:Name="Item1" Header="TabItem">
                <Grid Background="#FFE5E5E5">
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition/>
                        <ColumnDefinition Width="150"/>
                    </Grid.ColumnDefinitions>
                    <StackPanel x:Name="ControlsPanel" Grid.Column="1" Margin="0,0,0,0">
                        <Label x:Name="LoginLabel" Content="Label" Foreground="White" />
                        <TextBox controls:TextboxHelper.ClearTextButton="True" x:Name="LoginBox" Height="23" TextWrapping="Wrap" Text="" TextChanged="LoginBox_TextChanged"  />
                        <Label x:Name="PasswordLabel" Content="Label" Foreground="White"/>
                        <TextBox controls:TextboxHelper.ClearTextButton="True" x:Name="PasswordBox" Height="23" TextWrapping="Wrap" Text=""/>
                        <Label x:Name="AccessLabel" Content="Label" Foreground="White"/>
                        <ComboBox x:Name="AccessBox" VerticalAlignment="Top" Margin="0,0,0,0"/>
                        <Label x:Name="InfoLabel" Content="Label" Foreground="White"/>
                        <TextBox controls:TextboxHelper.ClearTextButton="True" x:Name="InfoBox" Height="23" TextWrapping="Wrap" Text=""/>
                        <Grid x:Name="ButtonsGrid" Height="Auto" VerticalAlignment="Top" Margin="0,5,0,0">
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto"/>
                                <RowDefinition Height="Auto"/>
                                <RowDefinition Height="Auto"/>
                            </Grid.RowDefinitions>
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="20*"/>
                                <ColumnDefinition Width="2*"/>
                                <ColumnDefinition Width="20*"/>
                            </Grid.ColumnDefinitions>
                            <Button x:Name="AddButton" Grid.Column="0" Grid.Row="0"  Grid.ColumnSpan="3" Content="Button" HorizontalAlignment="Center" Width="100" Height="30" VerticalAlignment="Center" />
                            <Button x:Name="AcceptButton" Grid.Column="0" Grid.Row="1"  Grid.ColumnSpan="3" Margin="0,4" Content="Button" HorizontalAlignment="Center" Width="100" Height="30" VerticalAlignment="Center" Click="AcceptButton_Click"/>
                            <Button x:Name="DeleteButton"  Content="Button" Grid.Row="2" HorizontalAlignment="Center" Width="60" Height="30" VerticalAlignment="Top" Grid.Column="0" Click="DeleteButton_Click"/>
                            <Button x:Name="CancelButton"  Content="Button" Grid.Column="1" Grid.Row="2" VerticalAlignment="Top" HorizontalAlignment="Center" Width="60" Height="30" Grid.ColumnSpan="2" Click="CancelButton_Click"/>
                        </Grid>
                        <Grid Height="36" VerticalAlignment="Bottom">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="5*"/>
                                <ColumnDefinition Width="9*"/>
                            </Grid.ColumnDefinitions>
                            <Label x:Name="ModeLabel"  Content="Label" Margin="0,0,0,0" Height="26" VerticalAlignment="Top" Foreground="White"/>
                            <Label x:Name="ModeTypeLabel" Content="Label" Grid.Column="1" VerticalAlignment="Top" Height="26" Margin="10,0,0,0" Foreground="White"/>
                        </Grid>
                    </StackPanel>
                    <DataGrid x:Name="DataG" SelectedCellsChanged="DataG_SelectedCellsChanged" HorizontalContentAlignment="Stretch" Margin="0,0,0,0" Sorting="DataG_Sorting" />
                </Grid>
            </TabItem>
        </TabControl>

    </Grid>
</UserControl>
